package com.example.test.factory.abstract_method;

import com.example.test.factory.abstract_method.ali.AliFacorty;
import com.example.test.factory.abstract_method.wechat.WechatFactory;

/**
 * @author 晓果冻
 * @version 1.0
 * @date 2021/12/9 22:53
 */
public class FactoryProducer {
    public static SuperFactory getFactory(String type){
        if(type.equals("ali")){
            return new AliFacorty();
        }else if(type.equals("wechat")){
            return new WechatFactory();
        }
        return null;
    }
}
